<?php
/**
 * Administrator model
 * @author Vanadia
 *
 */
class Admin_model extends Jiuchi_Model {
	public function __construct(){
		parent::__construct();
		$this->table = 'admin';
	}
	
	public function getAdminByUname($uname)
	{
	      $query = $this->db->get_where($this->table, array('account' => $uname));
	      return $query->row_array();
	}
	
	public function getAdminByUid($uid)
	{
	    $query = $this->db->get_where($this->table, array('id' => $uid));
	    return $query->row_array();
	}
}